function checkTime(time){
    if(time<10){
        time = "0"+time;
    }
    return time;
}

function showTime(){
    var d = new Date();
    var h = checkTime(d.getHours());
    var m = checkTime(d.getMinutes());
    var s = checkTime(d.getSeconds());
    var mp = document.getElementById("showTimes");
    mp.innerHTML = h+":"+m+":"+s;
    var timer = setTimeout("showTime()",1000);
}

showTime();

function addDate(date,days){
    var d = new Date(date);
    console.log(d.getDay());
    
    d.setDate(d.getDay()+days);
    var month = d.getMonth()+1;
    var day = d.getDate();
    if(month<10){
        month = "0"+month;
    }
    if(day<10){
        day = "0" + day;
    }
    var value = d.getFullYear()+"-"+month+"-"+day;
    return value;
}

console.log(addDate("2025-06-02"),30);

function show(){
    var myDate = document.getElementById("myDate");
    var myDateTime = document.getElementById("myDateTime");
    var myLocalDate= document.getElementById("myLocalDate");
    var myTime = document.getElementById("myTime");
    console.log(myDate.value);
    console.log(myDateTime.value);
    console.log(myLocalDate.value);
    console.log(myTime.value);
    
}

console.log("----------------------------");

console.log(Date.today());

